﻿<%@ Page Title="电池组实时监控数据" Language="C#" MasterPageFile="~/Web/Main.Master" AutoEventWireup="true" CodeBehind="groupDetail.aspx.cs" Inherits="BOMS.WebUI.Web.RealStatus.groupDetail" %>
<%@ Import Namespace="BOMS.WebUI.Web" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
<script type ="text/javascript">
$(document).ready(function () {
    setInterval("startRequest()",<%=Common.RefreshIntev%>);
});
function startRequest() {
    $("#groupdetail").load(location.href + " #groupdetail>*", "" + Math.random() + "");
}
function goGridPage(Batgrp) {
    window.location.href = "groupDetailInfo.aspx?WinceIp=<%=WinceIP%>&WinceMac=<%=WinceMac%>&WinceName="+encodeURI("<%=WinceName%>")+"&groupId=" + Batgrp;
}
function goChartPage(Batgrp){
    window.location.href = "groupDetailInfoChart.aspx?WinceIp=<%=WinceIP%>&WinceMac=<%=WinceMac%>&WinceName="+encodeURI("<%=WinceName%>")+"&groupId=" + Batgrp;
}
</script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
<div class="gv" id="groupdetail">
    <div class="gvtop"><asp:Label ID="title" runat="server"/><%--<b><asp:Button ID="Button1" runat="server" Text="返 回"  class="btnbg"/></b>--%></div>
    <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False"
    onrowdatabound="GridView1_RowDataBound" DataKeyNames="batterygroup" GridLines="None" 
    CssClass="gvstyle" HorizontalAlign="Center" CellSpacing="1" width="100%" 
        AllowSorting="True" onsorting="GridView1_Sorting">
    <Columns>
        <asp:BoundField DataField="BatteryGroup" HeaderText="电池组序号" 
            SortExpression="BatteryGroup" />
        <asp:BoundField DataField="Vval" HeaderText="总电压(V)" />
        <asp:BoundField DataField="Ival" HeaderText="总电流(A)" />
        <asp:BoundField DataField="CdFree" HeaderText="充放容量(Ah)" />
        <asp:BoundField DataField="CdTime" HeaderText="充放计时" />
        <asp:BoundField DataField="CapFree" HeaderText="实际容量(Ah)" />
        <asp:BoundField DataField="TimeFree" HeaderText="剩余可用时" 
            SortExpression="TimeFree" />
        <asp:BoundField DataField="Status" HeaderText="工作状态" /> 
<%--        <asp:BoundField DataField="WarningContentDescr" HeaderText="故障内容" />  --%> 
        <asp:TemplateField HeaderText="故障内容">
            <ItemTemplate>
                <asp:Literal runat="server" ID="ltrErrorDescr"></asp:Literal>
            </ItemTemplate>
        </asp:TemplateField>  
        <asp:TemplateField HeaderText="组内单体电池详细信息">
            <ItemTemplate>
                <input type="button" id="btnViewGrid" value="列 表" onclick=goGridPage('<%# Eval("BatteryGroup") %>'); />
                <input type="button" id="btnViewChart" value="柱形图" onclick=goChartPage('<%# Eval("BatteryGroup") %>'); />
            </ItemTemplate>
        </asp:TemplateField>
    </Columns>
        <FooterStyle CssClass="FooterStyle" />
        <RowStyle CssClass="gvrowstyle" />
        <EmptyDataRowStyle CssClass="EmptyRowStyle" />
        <PagerStyle CssClass="PagerStyle" />
        <SelectedRowStyle CssClass="SelectedRowStyle" />
        <HeaderStyle CssClass="gvtitle" />
        <EditRowStyle CssClass="EditRowStyle" />
        <AlternatingRowStyle CssClass="gvalternatingrowstyle" />
    </asp:GridView>
</div>
</asp:Content>